package eng.sim;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.Random;

import eng.model.Rating;
import eng.model.User;

public class Simulation {

	public static final int NUMBER_OF_TIMESTEPS = 1000;
	public static final int INITIAL_NUMBER_OF_AGENTS = 100;
	public static final int NUMBER_OF_AGENTS_TO_CREATE = 10;
	
	public static final String LOG_DIRECTORY = "";
	
	public static List<String> LOG = Arrays.asList(
									"",
									""
									); 

	public Random random = new Random();
	public ArrayList<User> users;
	public ArrayList<Rating> ratings;
	
	public void initialize() {
		
		users = new ArrayList<User>();
		createUsers(INITIAL_NUMBER_OF_AGENTS);

		ratings= new ArrayList<Rating>();
		
	}

	private void createUsers(int initialNumberOfAgents) {
		// TODO Auto-generated method stub
		
	}

	public void run() {
		
		
		for (int i = 0; i < NUMBER_OF_TIMESTEPS; i++) {
			
			/*====================================
			 * 	CREATION OF USERS
			 * ===================================*/
			createUsers(NUMBER_OF_AGENTS_TO_CREATE);
			
			/*====================================
			 * 	CREATION OF CONTENT
			 * ===================================*/
			for (int j = 0; j < users.size(); j++) {
				createContent(users.get(j));	
			}
			
			
			/*====================================
			 * 	RATE CONTENT
			 * ===================================*/
			for (int j = 0; j < users.size(); j++) {
				rateContent(users.get(j));	
			}
			
			/*====================================
			 * 	SUBSCRIPTIONS
			 * ===================================*/
			for (int j = 0; j < users.size(); j++) {
				subscribe(users.get(j));	
			}

			
		}
	
	}

	private void createContent(User user) {
		// TODO Auto-generated method stub
		
	}
	
	private void rateContent(User user) {
		// TODO Auto-generated method stub
		
	}
	
	private void subscribe(User user) {
		// TODO Auto-generated method stub
		
	}
	public static void main(String[] args) {
		Simulation sim = new Simulation();
		sim.initialize();
		sim.run();
	}

}
